#include<stdio.h>
#pragma warning(disable:4996)
int main()
{
	int a;
	scanf("%d",&a);
	int b = (a / 100) + (a % 100)*10 + (a % 10)*100;
	printf("%d", b);
}